import Mock from 'mockjs'
import { login, logout, getUserInfo } from './login'
import { getTableData, getDragList } from './data'
import {
  getGeneralSchedule,
  getAllByInstitute,
  getInstituteList,
  getScheduleByLab } from './mockSchedule.js'
import { getApplyFormList, getApplyFormDetail, getCourseType, getLabAppliedSummarySheet } from './mockApplyList.js'
import { getFirstWeekDateList } from './mockFirstWeekDate.js'
import {
  getTeacherList,
  getLabByTime,
  getLabByTimes,
  getCourseByTeacherCode,
  getClassesByCourse,
  submitApply,
  editApply,
  getMajorByGradeAndInstitute,
  // getInstituteList,
  getLabByDates,
  getDetailTable,
  addCourseSingleExp
} from './mockApply'
import { getLabList, getLabById, labSave } from './mockLabList.js'
import { getUserList, getUserById, userSave, getRolesType } from './mockUserList.js'
import { getExpDataInActiveLab } from './mockHome.js'

// 登录相关和获取用户信息
Mock.mock(/\/login/, login)
Mock.mock(/\/uaa\/user\/getUserInfo/, getUserInfo)
Mock.mock(/\/logout/, logout)
Mock.mock(/\/get_table_data/, getTableData)
Mock.mock(/\/get_drag_list/, getDragList)
Mock.mock(/\/get_drag_list/, getDragList)
Mock.mock(/\/info\/tea\/getTeachersByInstitute/, getTeacherList)
Mock.mock(/\/labm\/lab\/getAvailableLabCourse/, getLabByTimes)
Mock.mock(/\/labm\/lab\/getLabByUsageTime/, getLabByTime)
Mock.mock(/\/labm\/course\/getByTeacherCode/, getCourseByTeacherCode)
Mock.mock(/\/labm\/teachObject\/getByCourseCodeAndTeacherCode/, getClassesByCourse)
Mock.mock(/\/labm\/app\/addTable/, submitApply)
Mock.mock(/\/labm\/app\/modifyTable/, editApply)
Mock.mock(/\/labm\/teachObject\/getMajorByGrade/, getMajorByGradeAndInstitute)
Mock.mock(/\/labm\/getInstitute/, getInstituteList)
Mock.mock(/\/labm\/lab\/getAvailableLabTrain/, getLabByDates)
Mock.mock(/\/labm\/schedule\/getAll/, getGeneralSchedule)
Mock.mock(/\/labm\/lab\/getAllByInstitute/, getAllByInstitute)
Mock.mock(/\/labm\/getInstitute/, getInstituteList)
Mock.mock(/\/labm\/schedule\/getByLabCode/, getScheduleByLab)
Mock.mock(/\/labm\/app\/getDetailTable/, getDetailTable)
Mock.mock(/\/labm\/exp\/add/, addCourseSingleExp)
Mock.mock(/\/labm\/app\/getByTeaCode/, getApplyFormList)
Mock.mock(/\/labm\/app\/getDetailTable/, getApplyFormDetail)
Mock.mock(/\/info\/course\/getCourseType/, getCourseType)
Mock.mock(/\/labm\/schoolTime\/getAll/, getFirstWeekDateList)
Mock.mock(/\/labm\/lab\/getAll/, getLabList)
Mock.mock(/\/labm\/lab\/1/, getLabById)
Mock.mock(/\/labm\/lab\/save/, labSave)

Mock.mock(/\/uaa\/user\/getAll/, getUserList)
Mock.mock(/\/uaa\/user\/1/, getUserById)
Mock.mock(/\/uaa\/user\/save/, userSave)
Mock.mock(/\/uaa\/getRolesType/, getRolesType)

Mock.mock(/\/labm\/lab\/getExpDataInActiveLab/, getExpDataInActiveLab)
Mock.mock(/\/labm\/app\/getLabTableData/, getLabAppliedSummarySheet)

export default Mock
